<template>
<div id="index">
    <div id="video-list" v-for="video in videos">
        <router-link :to="{name:'video', params:{id:video.id}}">
            <img id="video-img" v-bind:src="video.img"/>
        </router-link>
        <router-link :to="{name:'video', params:{id:video.id}}">
            <p id="video-p">{{video.name}}</p>
         </router-link>
    </div>
</div>
</template>

<script>
export default {
  data() {
    return {
      videos: [
        {
          id:'1',
          img:'src/assets/logo.png',
          name:'硅谷',
          desc:''
        }
      ]
    }
  },
  ready(){
        var self = this;
        axios.post('video/list',{

        })
        .then(function (response){

        })
        .catch(function(error){

        });
    }
};
</script>

<style>

#video-list {
  margin: 10px;
  min-width: 300px;
  display: inline-block;
}
#video-img {
  /* width: 100%; */
  display: block;
  margin: auto;
}
#video-p {
  text-align: center;
}
</style>

